
package eSchool.DataLayer;

import java.sql.*;

public class DBUtils extends Object{

    public static Connection openAccessCon(String driver, String dbURL) throws SQLException, ClassNotFoundException, Exception {
        Connection con;
        
        Class.forName(driver);
        con = DriverManager.getConnection(dbURL);
        return con;
    }
    
    /** Fecha a Connection activa */
    public static void closeConnection(Connection con) throws SQLException{
        if (con != null) con.close();
        con = null;

    }
    
}

    